import { Request, Response, NextFunction } from 'express'

export default function (options: any = {}) {
    return function (req: Request, res: Response, next: NextFunction) {
        if (req.url.includes("upload"))
            console.log("req.method:", req.method, "req.headers:", req.headers);
        // let buffer:any=[];
        // req.on("data",(data:any)=>{
        //     buffer.push(data);
        // })
        // req.on("end",(data:any)=>{
        //    let result= Buffer.concat(buffer);
        //    console.log(result.toString('utf-8'))
        // })
        next();
    }
}



